-
Notifications
You must be signed in to change notification settings - Fork 74
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create dedicated cache and upstream metrics reports #189
Merged
oliveromahony
merged 31 commits into
nginx:main
from
karlsassenberg:add_seperate_cache_http_upstream_metrics_reports
Mar 27, 2023
Merged
Create dedicated cache and upstream metrics reports #189
oliveromahony
merged 31 commits into
nginx:main
from
karlsassenberg:add_seperate_cache_http_upstream_metrics_reports
Mar 27, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
✅ Deploy Preview for agent-public-docs canceled.
|
github-actions
bot
added
chore
Pull requests for routine tasks
dependencies
documentation
Improvements or additions to documentation
labels
Feb 2, 2023
karlsassenberg
force-pushed
the
add_seperate_cache_http_upstream_metrics_reports
branch
from
February 23, 2023 17:08
238fc98
to
099413b
Compare
dhurley
requested review from
oliveromahony,
dhurley,
aphralG,
craigell and
Dean-Coakley
February 28, 2023 10:31
dhurley
reviewed
Feb 28, 2023
karlsassenberg
force-pushed
the
add_seperate_cache_http_upstream_metrics_reports
branch
2 times, most recently
from
March 7, 2023 17:34
c38aaf0
to
e25d943
Compare
dhurley
reviewed
Mar 10, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. Just have a few minor comments
karlsassenberg
force-pushed
the
add_seperate_cache_http_upstream_metrics_reports
branch
from
March 10, 2023 16:23
e25d943
to
0735d86
Compare
dhurley
approved these changes
Mar 15, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
I verified that the metrics REST & gRPC APIs work as expected with this change.
dhurley
removed
documentation
Improvements or additions to documentation
dependencies
labels
Mar 16, 2023
Dean-Coakley
approved these changes
Mar 16, 2023
oliveromahony
approved these changes
Mar 16, 2023
Split Nginx Plus MetricsReport into three groups of reports of the following types: CACHE_ZONE, UPSTREAMS and SYSTEM. A CACHE_ZONE report is created for each distinct value of the dimension "cache_zone". An UPSTREAMS report is created for each distinct value of the dimension "upstream". A SYSTEM report contains all other metrics.
Split Nginx Plus MetricsReport into three groups of reports of the following types: CACHE_ZONE, UPSTREAMS and SYSTEM. A CACHE_ZONE report is created for each distinct value of the dimension "cache_zone". An UPSTREAMS report is created for each distinct value of the dimension "upstream". A SYSTEM report contains all other metrics.
Split Nginx Plus MetricsReport into three groups of reports of the following types: CACHE_ZONE, UPSTREAMS and SYSTEM. A CACHE_ZONE report is created for each distinct value of the dimension "cache_zone". An UPSTREAMS report is created for each distinct value of the dimension "upstream". A SYSTEM report contains all other metrics.
Split Nginx Plus MetricsReport into three groups of reports of the following types: CACHE_ZONE, UPSTREAMS and SYSTEM. A CACHE_ZONE report is created for each distinct value of the dimension "cache_zone". An UPSTREAMS report is created for each distinct value of the dimension "upstream". A SYSTEM report contains all other metrics.
karlsassenberg
force-pushed
the
add_seperate_cache_http_upstream_metrics_reports
branch
from
March 22, 2023 13:29
0735d86
to
c45cdf2
Compare
github-actions
bot
added
dependencies
documentation
Improvements or additions to documentation
labels
Mar 22, 2023
craigell
approved these changes
Mar 24, 2023
dhurley
removed
documentation
Improvements or additions to documentation
dependencies
labels
Apr 13, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Split Nginx Plus MetricsReport into four reports of the following types: CACHE_ZONE, UPSTREAMS, INSTANCE and SYSTEM. A single CACHE_ZONE report is created containing all StatsEntities with the dimension "cache_zone". A single UPSTREAMS report is created containing all StatsEntities with the dimension "upstream". The SYSTEM report contains all system metrics and the INSTANCE report contains all instance level metrics. Before only a single report was created of type SYSTEM which contained all metrics.
Proposed changes
Split out plus.cache.* and plus.http.upstream.* metrics out from the generated MetricReport, each into their own dedicated MetricReport.
Notes:
Default value of metrics.mode in default.go was changed to "aggregated" instead of "aggregation" to match default nginx-agent.conf and internal code usages.
Empty MetricReports are suppressed.
Added two new types MetricsReport MetricsReport_CACHE_ZONE and MetricsReport_UPSTREAMS.
Refactored Existing tests and wrote new ones.
Manual testing done with the attached nginx conf nginx_caches_upstreams.conf.gz
where the logs were used to confirm the MetricReports were generated as expected and the analytics api was queried to confirm that the metrics were being persisted to clickhouse. Tested both streaming and aggregated metrics mode.
Checklist
Before creating a PR, run through this checklist and mark each as complete.
CONTRIBUTING
documentREADME.md
)